<?php

namespace App;

use Illuminate\Database\Eloquent\Model;

class PatientInfo extends Model {

	/**
	 * The database table used by the model.
	 *
	 * @var string
	 */
	protected $table = 'patient';

	/**
	 * The primary key used by the model.
	 *
	 *@var string
	 */
	protected $primaryKey = 'id';

	/**
	 * Each patient has multiple cases
	 *
	 * @return patient case
	 */
	public function cases() {
		return $this -> hasMany('App\PatientCase', 'patient_id', 'id');
	}
	/**
	 *  Get last modified photo as the cover page of the case 
	 */
	public function cover($patient_id) {
		
	}

}
